package com.api.day01stringtest;

public class StringBuilderTest {
    public static void main(String[] args) {
        StringBuilder sb = new StringBuilder();
        //添加
        sb.append("zero");
        System.out.println(sb);
        //索引删除
        sb.delete(0,3);
        System.out.println(sb);
        //索引替换
        sb.replace(0,10,"zero one");
        System.out.println(sb);
        //索引插入
        sb.insert(7," zero");
        System.out.println(sb);
    }
}
